package com.maori.languageapp.service;

import com.maori.languageapp.R;

import android.app.Activity;
import android.content.Context;
import android.os.AsyncTask;

public class Maori_Loading_Splash extends AsyncTask<String, Void, String> {

	private Activity activity;
	private Context context;
	private long LOAD_SCREEN_DELAY=2000;  //Load Screen Delay
	
	public Maori_Loading_Splash(Activity activity) {
		super();
		this.activity = activity;
		this.context = this.activity.getApplicationContext();
	}
	
	@Override
	protected String doInBackground(String... arg0) {
		try {
			Thread.sleep(LOAD_SCREEN_DELAY);
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
		return null;
	}
	
	@Override
	protected void onPostExecute(String result) {
		//activity.setContentView(R.layout.maori_login);
		activity.setContentView(R.layout.activity_main);
		
	}
}
